home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Visual Basic Controls
/
Visual Basic Controls.iso
/
vbcontrol
/
csplitba
/
csplitba.txt
< prev
next >
Wrap
Text File
|
1998-01-09
|
2KB
|
49 lines
CSplitBarCtrl.txt - Text file for CSplitBarCtrl.OCX
Copyright (c) 1998 Luis Reis, lreis@comnet.ca
The accompanying files may be distributed on the condition that they
are distributed in full and unchanged, and that no fee is charged for
such distribution with the exception of reasonable shipping and media
charges. In addition, the CSplitBarCtrl.OCX control may be
incorporated into your own programs and the resulting programs may be
distributed without payment of royalties, also the author is not
responsible in any way for ANY damages that may arise out of the use,
inability to use, or any data that this control may generate.
==========================================================================
CSplitBarCtrl.OCX allows you to create a movable split bar between two
controls (like the one in Windows Explorer), just by assigning the
CSplitBarCtrl control the left and right hwnd of the controls you want
to use it with.
Methods:
' **NOTE** The controls you wish to use the splitbar with must be put on top
' of the CSplitBarCtrl control to allow drawing on the child controls
'Required
CSplitCtrl.SetLeftChild ' hWnd of the left control
CSplitCtrl.SetRightChild ' hWnd of the right control
CSplitCtrl.ResizeControls ' Resize the controls (MUST be called
' after setting both hWnd's)
'Optional
CSplitBarCtrl.SetMaxMove ' Set the maximum that the split bar can be
' moved left or right (in Points)
CSplitBarCtrl.SetSplitBarEnabled ' Enable or disable the movement of the bar
Example:
To try this example, paste the code into the Declarations section of a
form with a CSplitBarCtrl control named CSplitBarCtrl1, then place a
ListBox control named List1 with the IntegralHeight property set to False,
and a Textbox control named Text1 into the CSplitBarCtrl1 control and then
press F5.
Private Sub Form_Load ()
CSplitCtrl1.SetLeftChild Text1.hWnd
CSplitCtrl1.SetRightChild List1.hWnd
CSplitCtrl1.ResizeControls
End Sub